#define _CRT_SECURE_NO_WARNINGS 1
#include<iostream>

using namespace std;

int a[101], b[101], m;

void copy(int a[], int b[], int size)
{
    for (int i = 0; i < size; i++)
    {
        b[i] = a[i];
    }
    for (int i = 0; i < m; i++)
        cout << b[i] << ' ';
}

int main()
{
    int n, size;
    cin >> n >> m >> size;
    for (int i = 0; i < n; i++)
        cin >> a[i];
    for (int i = 0; i < m; i++)
        cin >> b[i];

    copy(a, b, size);
    return 0;
}